﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

/// <summary>
/// 玩家指令消息基类
/// </summary>
[Message(3, "PlayerCommand")]
public abstract class PlayerCommandBase:ECSCompoentBase
{
    /// <summary>
    /// 玩家id
    /// </summary>
    public int id;
    /// <summary>
    /// 第几帧
    /// </summary>
    public int frame;
    /// <summary>
    /// 时间
    /// </summary>
    public int time;
    /// <summary>
    /// 玩家命令消息copy
    /// </summary>
    /// <returns></returns>
    public abstract PlayerCommandBase DeepCopy();
    /// <summary>
    /// 判断玩家指令是否一致（预测/实际接收）
    /// </summary>
    /// <param name="cmd"></param>
    /// <returns></returns>
    public abstract bool EqualsCmd(PlayerCommandBase cmd);
}

